{extend name="public/base"/}
{block name="style"}
{/block}
{block name="body"}
{include file="public/header" /}
<div class="bodySection">
            
    <div class="centerSection">

        <div class="registerSection">
            <div class="section_title2">
                用户注册
                <span  class="rightSection_titleRight">已有账号？请<a href="/login.html?backurl={$jumpurl|urlencode}">登录</a></span>
            </div>

            <div class="rightSection_border">

                <!--状态1 -->
                <div class="centerSection_register">
                    <div class="top_navBlock">
                        <div class="lis" style="text-indent: 20px;"><i class="icon1  ball01_active"></i>填写注册信息</div>
                        <div class="lis  delBottomLine"><i class="icon2  ball02"></i>注册成功</div>
                    </div>


                    <div class="block_form">
                        <ul>
                            <li>
                                <div class="block_form_input">
                                    <span class="icon1"></span>
                                    <input id="userphone" type="text" value="" class="inputText"  placeholder="请输入11位手机号"/>
                                            <span id="phonetip" class="error  error2" style="display: none;">
                                                    <i></i>格式有误
                                            </span>
                                </div>
                            </li>


                            <li>
                                <div class="block_form_input  form_input1">
                                    <span class="icon2"></span>
                                    <input id="userverify" type="text" value="" class="inputText"  placeholder="请输入验证码" />
                                            <span id="verifytip" class="error " style="display: none;">
                                                    <i></i>验证码有误
                                            </span>
                                </div>
                                <div id="getverifycode" class="block_form_input form_input2" onselectstart="return false;">
                                    获取验证码
                                </div>
                            </li>
                            <li>

                                <div class="block_form_input">
                                    <span class="icon3"></span>
                                    <input id="userpass" type="password" value="" class="inputText" placeholder="6-20字符, 可用字母/数字/下划线" />
                                            <span id="passtip" class="error  error2" style="display: none;">
                                                    <i></i>格式不对
                                            </span>
                                </div>
                            </li>
                            <li>
                                <div class="block_form_input">
                                    <span class="icon3"></span>
                                    <input id="userpass2" type="password" value="" class="inputText" placeholder="请再次输入密码" />
                                            <span id="pass2tip" class="error" style="display: none;">
                                                    <i></i>密码不一致
                                            </span>
                                </div>
                            </li>
                        </ul>
                    </div>

                    <div id="submitbtn" class="block_form_button">
                        确认注册
                    </div>

                    <div class="agreeCheckbox" style="text-align: center;"><i class="active  checkboxPlugin" id="useragree" style="left: 90px; " ></i>我已阅读并同意《<a href="/news/detail/6.html">用户服务协议</a>》</div>

                </div>




            </div>

        </div>

    </div>
</div>
{block name="include"}{include file="public:footer" /}{/block}
{/block}
{block name="script"}
   <script type="text/javascript" src="/public/lboyue/js/user.js"></script>
    <script type="text/javascript">

        $(document).ready(function () {

            inputcheck($("#userphone"),reg_phone,$("#phonetip"));
            inputcheck($("#userpass"),reg_pass,$("#passtip"));
            inputcheck($("#userverify"),reg_verify,$("#verifytip"));
            inputcheck($("#userpass2"),reg_pass,$("#pass2tip"),function(){

                var pass1=$("#userpass").val();
                var pass2=$("#userpass2").val();
                if(pass1!=pass2)
                {
                    $("#pass2tip").html("<i></i>密码不一致");
                    $("#pass2tip").show();
                }
            },function(){
                $("#pass2tip").html("<i></i>格式不对");
            });

            bindverifycode($("#getverifycode"),$("#userphone"),1,0);
            $("#submitbtn").click(function () {
                var phone = $("#userphone").val();
                var userverify = $("#userverify").val();
                var userpass = $("#userpass").val();
                var userpass2 = $("#userpass2").val();
                var reurl = "{$jumpurl|urlencode}";

                if(userpass!=userpass2)
                {
                    $("#pass2tip").html("<i></i>密码不一致");
                    $("#pass2tip").show();
                    return;
                }
                var checkuser = checkuseragree();
                if (checkuser == "") {
                    malert("您必须先同意用户协议，才能继续注册");
                    return "";
                }
                phonereg(phone,userverify,userpass,reurl);


            });
            setuseragree();
        });


    </script>
<script>
    $(document).ready(function () {
        bindnews();
        bindbookshelf();
        bindnav();
    });

</script>
{/block}


